package com.feature.learn.concurrent.Semaphore.sampe1;

/**
 * https://www.cnblogs.com/klbc/p/9500947.html
 * @Description
 * @create 2021/7/2
 * @since 1.0.0
 */
public class ServiceThread extends Thread {

    private SemaphoreService service;

    public ServiceThread(String name,  SemaphoreService service) {
        super();
        this.setName(name);
        this.service = service;
    }

    @Override
    public void run() {
        this.service.doSomething();
    }
}